<!--
 * Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved.
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 * This code is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License version 2 only, as
 * published by the Free Software Foundation.  Oracle designates this
 * particular file as subject to the "Classpath" exception as provided
 * by Oracle in the LICENSE file that accompanied this code.
 *
 * This code is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 * version 2 for more details (a copy is included in the LICENSE file that
 * accompanied this code).
 *
 * You should have received a copy of the GNU General Public License version
 * 2 along with this work; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 *
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores
 * CA 94065 USA or visit www.oracle.com if you need additional information or
 * have any questions.
-->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <title>9 Part Image Border Wizard</title>
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
  </head>
  <body>
    <p>
        This wizard is useful for creating 9 part image borders to components,
        these borders allow adapting UI's without scaling to multiple resolution
        by dividing the image to 9 distinct parts. as such:<br>
        <img src="9patchdemo.png" /><br>
        The component can thus grow or shrink (to some extent) based on the following
        criteria:
    </p>
    <ol>
        <li>Corners never shrink and are drawn only once, the border will thus never
        be smaller than the sum size of top left, top right, bottom left and bottom right</li>
        <li>The top, bottom, left, right and center portions are tiled and optinally cropped
        thus they can appear multiple times or not at all.</li>
    </ol>
    <p>
        Notice that using larger images rather than a single pixel image for the tiled
        sections is far more efficient on devices. Also keep in mind that a gradient
        image would need to be cut in a way that would not break the flow of the
        gradient (e.g. place the lines as close as reasonable to one another).
    </p>

    <p>
        To use this wizard first you need to pick or create an image using the first page
        you are presented with a radio button that allows you to pick a ready made file
        or a set of controls to create simple yet attractive images. Once you have an image
        to your satisfaction you need to place the cutting guides in the right place.
    </p>

    <p>
        The next step is picking the component UIID's and the states to which the border
        should be applied. The component UIID's can be selected or typed in and the border
        can be applied to a specific state. A border can be applied to multiple components
        at once.<br>
        Notice that a border generates multiple images so it is much more useful to create
        a border once and apply it to multiple components than generate a border for
        every component!
    </p>
  </body>
</html>
